package pvn.com;

import net.rim.device.api.ui.component.LabelField;

public class WideField extends LabelField {
    public int width = 0;

    public WideField(int _width) {
        this.width = _width;
    }

    public int getPreferredWidth() {
        if (this.width > 0) {
            return this.width;
        }
        return super.getPreferredWidth();
    }

    public void layout(int maxW, int maxH) {
        super.layout(this.width, maxH);
        setExtent(this.width, maxW);
    }
}